.tdc-analyzer {
  display: flex;
  flex-direction: column;
  height: 100%;
  max-height: calc(100vh - 120px);
  background: #0d1117;
  overflow: hidden;
}

.analyzer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: #21262d;
  border-bottom: 1px solid #30363d;
  flex-shrink: 0;
}

.analyzer-header h3 {
  margin: 0;
  color: #f0f6fc;
  font-size: 16px;
  font-weight: 600;
}

.marker-count {
  font-size: 12px;
  color: #58a6ff;
  background: rgba(88, 166, 255, 0.1);
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid rgba(88, 166, 255, 0.2);
}

/* 时间间隔信息样式 */
.time-interval-info {
  margin-top: 8px;
  padding: 6px 12px;
  background: rgba(46, 160, 67, 0.1);
  border: 1px solid rgba(46, 160, 67, 0.2);
  border-radius: 4px;
  font-size: 11px;
}

.time-info {
  color: #2ea043;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 4px;
}

.time-info.default {
  color: #f85149;
  background: rgba(248, 81, 73, 0.1);
  border: 1px solid rgba(248, 81, 73, 0.2);
  padding: 4px 8px;
  border-radius: 3px;
}

.tdc-chart-container {
  flex: 1 1 0;
  min-height: 250px;
  max-height: 70%;
  background: #0d1117;
  border-bottom: 1px solid #30363d;
  padding: 16px;
  overflow: hidden;
  position: relative;
}

.tdc-chart {
  width: 100%;
  height: 100%;
  min-height: 350px;
  border: 1px solid #30363d;
  border-radius: 6px;
  background: #161b22;
  display: block;
}

.no-data {
  flex: 1 1 0;
  min-height: 250px;
  max-height: 80%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  background: #0d1117;
  border-bottom: 1px solid #30363d;
  text-align: center;
}

.no-data-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.6;
}

.no-data p {
  margin: 0 0 20px 0;
  color: #8b949e;
  font-size: 14px;
  line-height: 1.5;
}

.instruction-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 12px;
  color: #6e7681;
}

.instruction-list div {
  background: #21262d;
  padding: 6px 12px;
  border-radius: 4px;
  border: 1px solid #30363d;
}

.marker-list {
  flex: 1 1 0;
  min-height: 200px;
  max-height: 80%;
  background: #161b22;
  border-top: 1px solid #30363d;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.marker-list-header {
  flex-shrink: 0;
  background: #21262d;
  border-bottom: 1px solid #30363d;
}

.marker-list-header h4 {
  margin: 0;
  padding: 12px 16px 8px;
  color: #f0f6fc;
  font-size: 14px;
  font-weight: 600;
}

.header-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 0 16px 12px;
  flex-wrap: wrap;
}

.batch-controls {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.batch-checkbox {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  color: #c9d1d9;
  font-size: 12px;
  transition: color 0.2s ease;
}

.batch-checkbox:hover {
  color: #f0f6fc;
}

.batch-checkbox input[type="checkbox"] {
  width: 14px;
  height: 14px;
  border: 1px solid #444c56;
  border-radius: 2px;
  background: #30363d;
  cursor: pointer;
  position: relative;
  appearance: none;
  transition: all 0.2s ease;
}

.batch-checkbox input[type="checkbox"]:checked {
  background: #1f6feb;
  border-color: #1f6feb;
}

.batch-checkbox input[type="checkbox"]:checked::after {
  content: '✓';
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 10px;
  font-weight: bold;
}

.batch-checkbox input[type="checkbox"]:hover {
  border-color: #58a6ff;
}

.checkbox-label {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

.save-annotations-btn {
  background: #238636;
  color: #ffffff;
  border: 1px solid #2ea043;
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.save-annotations-btn:hover {
  background: #2ea043;
  border-color: #46954a;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(35, 134, 54, 0.3);
}

.save-annotations-btn:active {
  background: #1a7f37;
  border-color: #2ea043;
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(35, 134, 54, 0.2);
}

.clear-all-btn {
  background: #da3633;
  color: #ffffff;
  border: 1px solid #f85149;
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.clear-all-btn:hover {
  background: #f85149;
  border-color: #fd7875;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(218, 54, 51, 0.3);
}

.clear-all-btn:active {
  background: #b91c1c;
  border-color: #f85149;
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(218, 54, 51, 0.2);
}

.empty-markers {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6e7681;
  font-size: 13px;
  padding: 20px;
}

.markers-container {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  padding: 6px;
}

.marker-item {
  background: #21262d;
  border: 1px solid #30363d;
  border-radius: 6px;
  padding: 8px;
  margin-bottom: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  min-height: 60px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.marker-item:hover {
  background: #2d333b;
  border-color: #444c56;
}

.marker-item.selected {
  background: #1f2937;
  border-color: #58a6ff;
  box-shadow: 0 0 0 2px rgba(88, 166, 255, 0.2);
}

.marker-header {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
}

.marker-color {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid #30363d;
  flex-shrink: 0;
}

/* 名称编辑相关样式 */
.marker-name {
  flex: 1;
  font-size: 13px;
  font-weight: 500;
  color: #f0f6fc;
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 3px;
  transition: background-color 0.2s ease;
}

.marker-name:hover {
  background-color: rgba(88, 166, 255, 0.1);
}

.marker-name-edit {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 4px;
}

.name-input {
  flex: 1;
  background: #21262d;
  border: 1px solid #444c56;
  border-radius: 4px;
  color: #f0f6fc;
  font-size: 12px;
  padding: 4px 6px;
  outline: none;
  transition: border-color 0.2s ease;
}

.name-input:focus {
  border-color: #58a6ff;
  box-shadow: 0 0 0 2px rgba(88, 166, 255, 0.1);
}

.edit-actions {
  display: flex;
  gap: 2px;
}

.save-btn,
.cancel-btn {
  width: 20px;
  height: 20px;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  padding: 0;
}

.save-btn {
  background: #238636;
  color: white;
}

.save-btn:hover {
  background: #2ea043;
}

.cancel-btn {
  background: #da3633;
  color: white;
}

.cancel-btn:hover {
  background: #f85149;
}

.visibility-controls {
  display: flex;
  gap: 4px;
  margin-right: 8px;
}

.visibility-btn {
  background: #30363d;
  border: 1px solid #444c56;
  border-radius: 3px;
  color: #6e7681;
  font-size: 12px;
  padding: 2px 4px;
  cursor: pointer;
  transition: all 0.2s ease;
  min-width: 24px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.visibility-btn:hover {
  background: #444c56;
  color: #c9d1d9;
}

.visibility-btn.active {
  background: #1f6feb;
  border-color: #1f6feb;
  color: #fff;
}

.visibility-btn.active:hover {
  background: #388bfd;
}

.delete-btn {
  background: none;
  border: none;
  color: #8b949e;
  font-size: 18px;
  cursor: pointer;
  padding: 0;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 3px;
  transition: all 0.2s ease;
}

.delete-btn:hover {
  background: #da3633;
  color: #fff;
}

.marker-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}

.marker-type {
  font-size: 11px;
  color: #8b949e;
  background: #30363d;
  padding: 2px 6px;
  border-radius: 3px;
}

.marker-coords {
  font-size: 11px;
  color: #8b949e;
  font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
}

.marker-stats {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 4px;
  padding-top: 6px;
  border-top: 1px solid #30363d;
  margin-top: auto;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
}

.stat-label {
  font-size: 9px;
  color: #6e7681;
  font-weight: 500;
}

.stat-value {
  font-size: 11px;
  color: #58a6ff;
  font-weight: 600;
  font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
}

/* 滚动条样式 */
.markers-container::-webkit-scrollbar {
  width: 6px;
}

.markers-container::-webkit-scrollbar-track {
  background: #21262d;
  border-radius: 3px;
}

.markers-container::-webkit-scrollbar-thumb {
  background: #484f58;
  border-radius: 3px;
}

.markers-container::-webkit-scrollbar-thumb:hover {
  background: #6e7681;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .analyzer-header {
    padding: 8px 12px;
  }
  
  .analyzer-header h3 {
    font-size: 14px;
  }
  
  .marker-count {
    font-size: 11px;
    padding: 3px 6px;
  }
  
  .tdc-chart-container {
    padding: 12px;
    min-height: 250px;
  }
  
  .tdc-analyzer {
    max-height: calc(100vh - 80px);
  }
  
  .marker-list {
    flex: 1 1 0;
    min-height: 150px;
    max-height: 80%;
  }
  
  .tdc-chart-container {
    flex: 1 1 0;
    min-height: 200px;
    max-height: 55%;
  }
  
  .marker-item {
    padding: 6px;
    min-height: 50px;
  }
  
  .marker-name {
    font-size: 12px;
  }
  
  .marker-stats {
    gap: 3px;
    grid-template-columns: 1fr 1fr;
  }
  
  .stat-value {
    font-size: 10px;
  }
  
  .stat-label {
    font-size: 8px;
  }
  
  .no-data {
    padding: 20px 15px;
  }
  
  .no-data-icon {
    font-size: 36px;
  }
  
  .instruction-list {
    font-size: 11px;
  }

  .header-controls {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  .save-annotations-btn {
    width: 100%;
    justify-content: center;
    padding: 8px 12px;
  }

  .batch-controls {
    justify-content: center;
  }
}